<extend name="Public/base"/>
<block name="body">
  
	<!-- 标题栏 -->
	<div class="main-title">
		<h2>{$meta_title}</h2>
	</div>

	    <div  class="with-padding">
                <div class="fl">
                    <a href="__ROOT__/Application/Wckc/Static/tmplfile/wckcClass.xlsx" class="btn btn-success">下载导入模板</a>&nbsp;
                    
                    <a href="{:U('addClass')}" class="btn btn-ajax btn-success btn">新增</a>&nbsp;
                    <button class="btn ajax-post btn-info btn" url="/web2016/index.php?s=/admin/Wckc/setcategorystatus.html&amp;status=1" target-form="ids">启用</button>&nbsp;
                    <button class="btn ajax-post btn-warning btn" url="/web2016/index.php?s=/admin/Wckc/setcategorystatus.html&amp;status=0" target-form="ids">禁用</button>&nbsp;
                    <button class="btn ajax-post btn-danger btn" url="/web2016/index.php?s=/admin/Wckc/setcategorystatus.html&amp;status=-1" target-form="ids">删除</button>&nbsp;

                </div>
            </div>


    <div class="with-padding">
        <form id="addform" action="{:U('importClass')}" enctype="multipart/form-data" method="post" class="form-horizontal">          
        <div class="form-group">
          <label class="col-md-1 control-label" >Excel表格：</label> 
          <div class="col-md-2">
                <input type="file" name="excelData" value="" />
                <span class="Validform_checktip"></span>
            </div>
          <div class="col-md-1">
          <img  src="__PUBLIC__/images/loading.gif" style="display:none;"/>
          <input type="submit" class="btn btn-primary" value="导入" />
          </div> 
        </div>
    </form>
    <link href="__PUBLIC__/zui/lib/uploader/zui.uploader.min.css" rel="stylesheet">
<script src="__PUBLIC__/zui/lib/uploader/zui.uploader.min.js"></script>  
<div class="example">
  <div id="uploaderExample" class="uploader file-drag-area uploader-rename" data-auto-upload="true" data-drop-placeholder="将文件拖放至在此处。">
    <div class="uploader-files file-list file-rename-by-click" data-drag-placeholder="请拖拽文件到此处"><div class="file" id="file-o_1c4upu0b0omj140e4rd1rcoeng1k" data-status="done"><div class="file-progress-bar" style="width: 100%;"></div><div class="file-wrapper"><div class="file-icon" style="color: rgb(38, 31, 173);"><i class="icon icon-file-word file-icon-doc" data-type="application/msword" data-ext="doc"></i></div><div class="content"><div class="file-name">2017教工运动会报名表-1.doc</div><div class="file-size small text-muted">20 KB</div></div><div class="actions"><div class="file-status" data-toggle="tooltip" data-original-title="已上传" title=""><i class="icon"></i> <span class="text"></span></div><a data-toggle="tooltip" class="btn btn-link btn-download-file" target="_blank" title="" download="2017教工运动会报名表-1.doc" data-original-title="下载" href="http://httpbin.org/post"><i class="icon icon-download-alt"></i></a><button type="button" data-toggle="tooltip" class="btn btn-link btn-reset-file" title="" data-original-title="重新上传"><i class="icon icon-repeat"></i></button><button type="button" data-toggle="tooltip" class="btn btn-link btn-rename-file" title="" data-original-title="重命名"><i class="icon icon-pencil"></i></button><button type="button" data-toggle="tooltip" title="" class="btn btn-link btn-delete-file" data-original-title="移除"><i class="icon icon-trash text-danger"></i></button></div></div></div></div>
    <button type="button" class="btn btn-primary uploader-btn-browse"><i class="icon icon-cloud-upload"></i> 选择文件</button>
  <div class="uploader-btn-browse uploader-btn-hidden" style="z-index: 1;"></div><div id="html5_1c4uprfs1141e11nr1svd3odbka4_container" class="moxie-shim moxie-shim-html5" style="position: absolute; top: -1px; left: -1px; width: 1px; height: 1px; overflow: hidden; z-index: 0;"><input id="html5_1c4uprfs1141e11nr1svd3odbka4" style="font-size: 999px; opacity: 0; position: absolute; top: 0px; left: 0px; width: 100%; height: 100%;" multiple="" accept="" type="file"></div></div>
</div>
    <div id="uploaderExample" class="uploader">
  <div class="file-list" data-drag-placeholder="请拖拽文件到此处"></div>
  <button type="button" class="btn btn-primary uploader-btn-browse"><i class="icon icon-cloud-upload"></i> 选择文件</button>
</div>
<script>
$('#uploaderExample').uploader({
    autoUpload: true,            // 当选择文件后立即自动进行上传操作
    url: {:U('importClass')}  // 文件上传提交地址
});
</script>


<div id='myUploader' class="uploader" data-ride="uploader" data-url="{:U('importClass')}">
  <div class="uploader-message text-center">
    <div class="content"></div>
    <button type="button" class="close">×</button>
  </div>
  <div class="uploader-files file-list file-list-lg" data-drag-placeholder="请拖拽文件到此处"></div>
  <div class="uploader-actions">
    <div class="uploader-status pull-right text-muted"></div>
    <button type="button" class="btn btn-link uploader-btn-browse"><i class="icon icon-plus"></i> 选择文件</button>
    <button type="button" class="btn btn-link uploader-btn-start"><i class="icon icon-cloud-upload"></i> 开始上传</button>
  </div>
</div>
<script>
var options = {
    // 初始化选项
    autoUpload: true,
};
$('#myUploader').uploader(options);
</script>      
    </div>
    <!-- 数据表格 -->
    <div class="with-padding">
        <table id="table-data" class="table table-bordered table-striped table-hover">
            <!-- 表头 -->
            <thead>
            <tr>
                <th class="row-selected row-selected" style="width: 20px">
                    <input class="check-all" type="checkbox"/>
                </th>
                <th>ID</th><th>年级</th><th>班级编号</th><th>班级名称</th><th>班级简称</th><th>班主任</th><th>排序</th><th>操作</th>            </tr>
            </thead>

            <!-- 列表 -->
            <tbody>
            <volist name="list" id='vo'>
            <tr>
                    <td><input class="ids" type="checkbox" value="38" name="ids[]"></td>
                    <td style="width:auto;max-width: 150px;" class="text-ellipsis" >{$vo.id}</td>
                    <td style="width:auto;max-width: 150px;" class="text-ellipsis" >{$vo.grade}</td>
                    <td style="width:auto;max-width: 150px;" class="text-ellipsis" >{$vo.bj_code}</td>
                    <td style="width:auto;max-width: 150px;" class="text-ellipsis" >{$vo.bj_name}</td>
                    <td style="width:auto;max-width: 150px;" class="text-ellipsis" >{$vo.bj_name2}</td>
                    <td style="width:auto;max-width: 150px;" class="text-ellipsis" >{$vo.headteacher}</td>
                    <td style="width:auto;max-width: 150px;" class="text-ellipsis" >{$vo.sort}</td>
                    <td style="width:auto;max-width: 150px;" class="text-ellipsis" ><a href="/web2016/index.php?s=/admin/wckc/editclass/id/38.html">编辑</a> <a href="/web2016/index.php?s=/admin/wckc/deleteclass/ids/38.html">删除</a></td> 
                    </tr>
                    </volist>
                </tbody>
        </table>
    </div>






  
</block>